// 权限页面
const authPages = ['/pages/userinfo/userinfo','/pages/fav/fav','/pages/eidt/edit']
import {store} from '../store/index'
export default {
    router(e:any){
            let {url,params} = e.currentTarget.dataset;
          let isLogin = store.state.isLogin
            if(authPages.includes(url)&&!isLogin){
              url = '/pages/login/login'
            }
            if(!url){
              wx.showToast({
                title:"缺少跳转路径",
                icon:"error"
              })
              return 
            }
            wx.navigateTo({
              url
            })
    }
}